package shape;

import java.util.Scanner;

class Shape{
    final double PI = 3.1415926;

    double area(){
        return 0;
    }

    double perimeter(){
        return 0;
    }
}

class Oval extends Shape{
    private double longr;
    private double lowr;

    Oval(double a,double b){
        longr = a;
        lowr = b;
    }
    Oval(){
        longr = 0;
        lowr = 0;
    }

    double area(){
        return PI * longr * lowr;
    }

    double perimeter(){
        return 2 * PI * Math.sqrt((Math.pow(longr,2)+Math.pow(lowr,2))/2);
    }

    public String toString(){
        return "Oval(a:"+longr+","+"b:"+lowr+")";
    }
}

public class ShapeTest {
    public static void main(String[] args) {
        Scanner reader = new Scanner(System.in);
        double longr = reader.nextDouble();
        double lowr = reader.nextDouble();
        Oval o1 = new Oval(longr,lowr);
        System.out.println("The area of "+o1.toString()+" is "+o1.area());
        System.out.println("The perimeterof "+o1.toString()+" is "+o1.perimeter());

    }
}
